package com.zf.mo.quartz;

public class QuartzTest {

//    public static void main(String[] args) {
//        int count = 0;
//        JobDataMap dataMap = new JobDataMap();
//        dataMap.put("job","jobValue");
//        JobDetail jobDetail = JobBuilder.newJob(MyJob.class)
//                .withIdentity("myJobName", "myJobGroup")
//                .usingJobData("count",count)
//                .usingJobData(dataMap)
//                .build();
//        Trigger trigger = TriggerBuilder.newTrigger()
//                .withIdentity("triggerName", "triggerGroup")
//                .usingJobData("trigger","triggerValue")
//                .startNow()
//                .withSchedule(SimpleScheduleBuilder.simpleSchedule().withIntervalInSeconds(1).repeatForever())
//                .build();
//        try {
//            Scheduler scheduler = StdSchedulerFactory.getDefaultScheduler();
//            scheduler.scheduleJob(jobDetail,trigger);
//            scheduler.start();
//        } catch (SchedulerException e) {
//            e.printStackTrace();
//        }
//
//
//    }
}
